import 'package:fish_redux/fish_redux.dart';

enum PatrolOrderResultViewAction {
  action,
  onTapStatus,
  onTapAddPic,
  setOrderPhoto,
  onTapPic,
  onSubmit,
  onTapSign,
  onTapResultPic,
  onGetData,
  onTapAddFixPic,
  onTapFixPic,
  setFixPhoto,
}

class PatrolOrderResultViewActionCreator {
  static Action onAction() {
    return const Action(PatrolOrderResultViewAction.action);
  }

  static Action onTapStatus(index) {
    return Action(PatrolOrderResultViewAction.onTapStatus, payload: index);
  }

  static Action onTapAddPic() {
    return const Action(PatrolOrderResultViewAction.onTapAddPic);
  }

  static Action setOrderPhoto(data) {
    return Action(PatrolOrderResultViewAction.setOrderPhoto, payload: data);
  }

  static Action onTapPic(data) {
    return Action(PatrolOrderResultViewAction.onTapPic, payload: data);
  }

  static Action onSubmit() {
    return const Action(PatrolOrderResultViewAction.onSubmit);
  }

  static Action onTapSign() {
    return const Action(PatrolOrderResultViewAction.onTapSign);
  }

  static Action onTapResultPic(model, data) {
    return Action(PatrolOrderResultViewAction.onTapResultPic,
        payload: {'model': model, 'data': data});
  }

  static Action onGetData(data) {
    return Action(PatrolOrderResultViewAction.onGetData, payload: data);
  }

  static Action setFixPhoto(data) {
    return Action(PatrolOrderResultViewAction.setFixPhoto, payload: data);
  }

  static Action onTapFixPic(data) {
    return Action(PatrolOrderResultViewAction.onTapFixPic, payload: data);
  }

  static Action onTapAddFixPic() {
    return const Action(PatrolOrderResultViewAction.onTapAddFixPic);
  }
}
